package com.yuelife.user.pojo;

import java.io.Serializable;
import lombok.Data;

/**
 * home
 * @author 
 */
@Data
public class Home implements Serializable {
    /**
     * 业主主键
     */
    private Integer homeId;

    /**
     * 业主姓名
     */
    private String homeName;

    /**
     * 小区id
     */
    private Integer areaId;

    /**
     * 小区单元
     */
    private String unitId;

    /**
     * 门牌号
     */
    private String hoseNumber;

    /**
     * 描述
     */
    private String description;

    /**
     * 电话
     */
    private String telephone;

    /**
     * 物业认证
     */
    private Integer propertyId;

    /**
     * 小区名字
     */
    private String areaName;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Home other = (Home) that;
        return (this.getHomeId() == null ? other.getHomeId() == null : this.getHomeId().equals(other.getHomeId()))
            && (this.getHomeName() == null ? other.getHomeName() == null : this.getHomeName().equals(other.getHomeName()))
            && (this.getAreaId() == null ? other.getAreaId() == null : this.getAreaId().equals(other.getAreaId()))
            && (this.getUnitId() == null ? other.getUnitId() == null : this.getUnitId().equals(other.getUnitId()))
            && (this.getHoseNumber() == null ? other.getHoseNumber() == null : this.getHoseNumber().equals(other.getHoseNumber()))
            && (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
            && (this.getTelephone() == null ? other.getTelephone() == null : this.getTelephone().equals(other.getTelephone()))
            && (this.getPropertyId() == null ? other.getPropertyId() == null : this.getPropertyId().equals(other.getPropertyId()))
            && (this.getAreaName() == null ? other.getAreaName() == null : this.getAreaName().equals(other.getAreaName()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getHomeId() == null) ? 0 : getHomeId().hashCode());
        result = prime * result + ((getHomeName() == null) ? 0 : getHomeName().hashCode());
        result = prime * result + ((getAreaId() == null) ? 0 : getAreaId().hashCode());
        result = prime * result + ((getUnitId() == null) ? 0 : getUnitId().hashCode());
        result = prime * result + ((getHoseNumber() == null) ? 0 : getHoseNumber().hashCode());
        result = prime * result + ((getDescription() == null) ? 0 : getDescription().hashCode());
        result = prime * result + ((getTelephone() == null) ? 0 : getTelephone().hashCode());
        result = prime * result + ((getPropertyId() == null) ? 0 : getPropertyId().hashCode());
        result = prime * result + ((getAreaName() == null) ? 0 : getAreaName().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", homeId=").append(homeId);
        sb.append(", homeName=").append(homeName);
        sb.append(", areaId=").append(areaId);
        sb.append(", unitId=").append(unitId);
        sb.append(", hoseNumber=").append(hoseNumber);
        sb.append(", description=").append(description);
        sb.append(", telephone=").append(telephone);
        sb.append(", propertyId=").append(propertyId);
        sb.append(", areaName=").append(areaName);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}